<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<table class="table table-striped table-bordered table-hover dataTables-example">
    <thead>
    <tr>
        <th>Id</th>
        <th>标题</th>
        <th>栏目</th>
        <th>状态</th>
        <th>创建时间</th>
        <th>操作</th>
    </tr>
    </thead>
    <tbody>

    <tr class="gradeX" th:each="article : ${articleList}">
        <td th:text="${article.id}"></td>
        <td>
            <a target="_blank" th:href="'/article/details/'+${article.id}" th:text="${article.title}">
            </a>
        </td>
        <td th:text="${article.columnName}">
        </td>
        <td th:text="${article.status}==1?'正常':'关闭'">

        </td>
        <td th:text="${#dates.format(article.createTime,'yyyy-MM-dd')}">2016-10-14 10:41:50</td>
        <td th:data-id="${article.id}" th:data-state="${article.status}">
            <button class="btn btn-primary btn-xs article-edit" title="编辑" type="button">
                编辑
            </button>


            <button class="btn btn-info btn-xs article-state" th:text="${article.status}!=1?'正常':'关闭'"
                    th:title="${article.status}!=1?'正常':'关闭'"
                    type="button">
                关闭
            </button>

            <button class="btn btn-danger btn-xs article-delete" title="删除" type="button">
                删除
            </button>


        </td>
    </tr>


    </tbody>
</table>

</html>